#pragma  once

#include "opencvandstd.h"
#include "invertedIndex.h"
#include "findfiles.h"
#include "utilities.h"

//#define USE_SVM
bool sortFunc(pair<string,float> &p1,pair<string,float> &p2);

bool solveAffine(KeyPoint & key, featureRecord &fr,houghParam &resultParam);


bool getParamRange(vector<houghParam> &parameters,houghParam &min_param ,houghParam &max_param);

int doHoughTransform(vector<houghParam> &parameters,int * param_space);

#ifdef USE_SVM
string makeDecision(map<LogoImgInfo,float> &final_score,vector<string> &totalLogoImgName
	,vector<string> &logoNames,CvSVM &classifier);
#else	
string makeDecision(map<LogoImgInfo,float> &final_score,vector<string> &totalLogoImgName
	,vector<string> &logoNames,CvRTrees &classifier);
#endif

void imgResize(Mat &source , Mat &dst , int maxSize);